package com.amap.search.entity.vo;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.util.List;

/**
 * 更多的返回具体信息可参考：
 * https://lbs.amap.com/api/webservice/guide/api/search
 */
@ApiModel(description = "高德地图兴趣点搜索结果")
@Data
public class AmapPoiResponse extends AmapBaseResponse {

    @ApiModelProperty("搜索POI信息列表")
    private List<Poi> pois;

    @ApiModelProperty("城市建议列表【暂时用不到的字段】")
    private Object suggestion;

    @Data
    public static class Poi{
        @ApiModelProperty("唯一ID")
        private String id;

        @ApiModelProperty("名称")
        private String name;

        @ApiModelProperty("兴趣点类型")
        private String type;

        @ApiModelProperty("兴趣点类型编码")
        private String typecode;

        @ApiModelProperty("详细地址")
        private Object address;

        @ApiModelProperty("特色内容")
        private Object tag;

        @ApiModelProperty("经纬度")
        private String location;

        @ApiModelProperty("联系电话")
        private Object tel;

        @ApiModelProperty("省名")
        private String pname;

        @ApiModelProperty("城市名")
        private String cityname;

        @ApiModelProperty("区域名")
        private String adname;

        @ApiModelProperty("区域编码")
        private String adcode;

        @ApiModelProperty("地图更新时间")
        private String timestamp;

        @ApiModelProperty("用户评价")
        private BizExt biz_ext;

        @ApiModelProperty("景点照片")
        private List<Photo> photos;
    }

    @Data
    public static class BizExt{
        @ApiModelProperty("评分")
        private Object rating;

        @ApiModelProperty("人均消费")
        private Object cost;
    }

    @Data
    public static class Photo{
//        @ApiModelProperty("图片简介")
//        private List<Object> title;
        @ApiModelProperty("图片连接")
        private String url;
    }
}
